|
|
|
| |
WebLogic Frequently Asked Questions: Server-related questions
I set the time zone in my environmnent to China Taiwan Time (CTT) but the
WebLogic Server log reports that the time zone is Central Standard Time (CST).
What's wrong?
This is a bug in the JDK confirmed by JavaSoft. The bug causes the WebLogic
Server log to erroneously report that it is using CST instead of CTT although the actual
time conversion is correct. There is currently no workaround, but JavaSoft reports that
this bug is fixed in JDK 1.2.
I am experiencing problems trying to connect from behind a firewall/proxy
installation at client sites. Is there any way to configure WebLogic to use a SOCKS
proxy?
You can configure a java.net socket to use SOCKS by setting a Java system
property. For details, see How do I make Java work with a proxy server?. Once the
property is set, WebLogic's socket connections will use the SOCKS proxy.
Can I speed up connection requests?
We recently installed a WebLogic Server, and found that it seems to take 15-30
seconds to respond to connection requests, even when there is no significant load. How
can I speed up connection delays?
Connection delays are often caused by DNS problems. WebLogic performs a
reverse lookup on the hostname from which a new connection is made. If the DNS
reverse lookup is not working properly because the connection is coming from some
kind of proxy server, it could be responsible for the delay. You might want to work
with your system administrator to determine whether DNS and the third-party
networking software are working properly. Try writing a simple server program that
performs a reverse lookup on any connection made to it. If that lookup is delayed, then
you know that the proxy server is the source of the problem.
Does WebLogic use CORBA? Is it an ORB?
What kind of information can you give me about WebLogic's CORBA support?
How can CORBA clients communicate with the WebLogic Server via IIOP?
"CORBA" support means many things to many people. Most frequently, it seems
to mean simply IIOP /ORB support and not much on CORBA services. WebLogic
supports CORBA in multiple ways.
First, Java clients can tunnel through a CORBA environment to a WebLogic Server. We call this "IIOP tunneling," and it is intended for use with applets coming through an IIOP firewall, such as the IONA Wonderwall product. This is a Java-to-Java model riding over an IIOP communications framework.
WebLogic RMI over IIOP provides RMI services for many clients (including CORBA clients) over IIOP. For more information, see Using WebLogic RMI over IIOP.
WebLogic Enterprise Connectivity gives you the ability to create IIOP connection pools to a BEA WebLogic Enterprise, allowing you to execute WebLogic Enterprise CORBA objects from WebLogic Server servlets and Enterprise JavaBeans.
Which WebLogic classes do I need to jar up for my client app?
I'm preparing to deploy my WebLogic client application, and I want to separate
out those classes that the client will not need. How do I do that?
It depends on what your client application does. The easy answer is to jar
everything in the weblogic/classes directory, as well as the weblogicaux.jar shipped in
the weblogic/bin directory.
If your client is a Java application or applet , you may be able to be more selective about which classes you ship to your client. You can use one of the utilities to help you.
The best solution is to use WebLogic ZAC. ZAC (Zero Administration Client) lets you publish your client application for automagic installation on your client machine. ZAC includes features for generating a tiny bootstrapping application that a client can download. It automatically contacts the publishing WebLogic Server to install the client application and then updates it automatically whenever you publish changes.
HTTP tunneling is slow! How can I speed it up?
Unfortunately, there is a significant performance hit when using HTTP tunneling.
We hav optimized it somewhat, but because everything is encapsulated in HTTP, it is
slower than non-secure communications. We continue to look for ways to optimize our
implementation.
Be sure that you really need to use HTTP tunneling. For example, if your firewall can pass IP packets through port 80, you can use the fast t3 protocol on port 80.
If you must use HTTP tunneling to go through a firewall, http://www.socks5.com/ has a product that performs better than HTTP proxies.
Using Netscape security certificates with WebLogic
I have a Netscape security certificate in ServerKey.der. How do I obtain just the
private key?
Netscape stores the private and public keys together in a key-pair file, which
prevents you from separating the public and private keys. In weblogic.properties, the
property entry [weblogic.security.key.server] refers only to the Private Key file.
Therefore, you must generate another request for a certificate, not using Netscape
utilities. You can use the Certificate Request servlet to generate a request for a new
certificate. Using WebLogic SSL shows how to use the servlet.
Starting the WebLogic Server automatically with a UNIX boot
How do I set up the WebLogic Server to execute whenever I reboot the UNIX
server?
You can add a startup script to your UNIX rc scripts to run the WebLogic Server
at UNIX boot time. Here is an example from an HP-UX 11 system, running under JDK
1.1. You need to supply the URL for your WebLogic Server and your system
password. This file, wlstart, is placed in the /sbin/init.d directory and there is a
link to it in the /sbin/rc2.d directory:
export SHLIB_PATH=\
/home/user1/weblogic/lib/hpux11:/oracle/8.0.4/lib
export CLASSPATH=/home/user1/weblogic/classes:\
/home/user1/weblogic/lib/weblogicaux.jar
export ORACLE_HOME=/oracle/8.0.4
export ORACLE_SID=DEMO
export ORACLE_TERM=vt100
export QAT=/home/user1/weblogic
cd $QAT
PATH=/sbin:/usr/sbin:/usr/bin:/opt/java/bin
export PATH
case $1 in
'start')
java -ms64m -mx64m -verbosegc weblogic.Server > \
/home/user1/weblogic/server.out 2>&1
;;
'stop')
java weblogic.Admin URL shutdown system password
;;
*)
echo "usage: $0 {start|stop}"
;;
esac
You should work with your UNIX system administrator to set up scripts similar to this for your system.
Servlet performance seem a big sluggish on your NT machine?
I'm serving several HTTP servlets over my internal network. Sometimes they are
really fast, while at other times the performance seems sluggish. There doesn't seem
to be a correlation with actual clients or even network traffic. From the local machine
itself, the response time is very fast. Very mysterious. Any ideas?
As it turns out, we have seen such mysterious behavior ourselves, and we finally
tracked it down to something completely unrelated to the network or client usage:
response time for a servlet is about 5 times slower when you are running a screen saver
on the machine, particularly for the OpenGL screen savers. You might try turning off
your screen saver and see if that helps!
"NoClassDefFound" / "Too many open files" errors on Solaris
I'm using WebLogic Server on Solaris. When I try to run my application, I get a
"NoClassDefFound" error, although I can see that the class causing the error does exist
and is in the right directory. In fact, there are other classes in the same directory that
are getting loaded. What's the problem?
I'm using WebLogic Server on Solaris. When I try to run my application, I get a "Too many open files" error. What's the problem?
We have seen this situation when the user account runs out of file descriptors. On
Solaris, each user account has a certain limited number of file descriptors. You can find
out how many file descriptors you have with the limit command in csh.
You can increase file descriptors if you have enough privileges with the ulimit command in the csh. Otherwise, ask your system administrator to increase the file descriptors available to your processes.
Another solution is to create a .jar file with all of the WebLogic classes, since a .jar file only requires a single file descriptor.
I can't get the WebLogic Server to start
When I try to start the WebLogic Server, I get a "Fatal Error: Cannot open
d:\weblogic.properties" message. I've installed the WebLogic: classes in a directory in
my CLASSPATH. What is the weblogic.properties file, and why can't the
WebLogic Server find it?
The weblogic.properties file contains configuration information for your
WebLogic Server environment. It is shipped in your distribution kit. Unless you use
InstallShield under Windows NT, you must edit the properties file before you try to
start the WebLogic Server, to set host, port, system password, and other WebLogic
Server configuration information. For more on the properties file, see Setting
WebLogic properties. Once edited, the file should be placed in your weblogic/
directory, along with a subdirectory called "myserver".
When you start the WebLogic Server, it looks first for the properties file in the current directory, and then it checks the path you supply on the command line as weblogic.system.home.
You can cd to the directory containing your weblogic.properties file and start the WebLogic Server with the command line example described in Setting up and Starting the WebLogic Server.
Or, if you prefer, you can start the WebLogic Server from any directory using the -D option to set weblogic.system.home. For example, if you have installed the properties file in the directory d:\net\weblogic\weblogic.properties, add this to the command line example:
% java ... -Dweblogic.system.home=d:\net\weblogic\ ...
Startup scripts are provided in the distribution. You can customize these scripts for your system. There are complete instructions on setting up, running, and managing the WebLogic Server in the Administrator Guide, Managing the WebLogic Server.
Problems with the WebLogic Server running out of memory
When I run the WebLogic Server, it runs out of memory very quickly. How do I
fix this?
I'm using the WebLogic Server for a large number of client connection requests, and occasionally there are memory problems. How can I remedy this?
Increase the allocation of Java heap memory for the WebLogic Server. (Both the
minimum and the maximum should be set to the same size.) Start the WebLogic Server
with the -ms32m option to increase the allocation, as in this example:
$ java ... -ms32m -mx32m ...
This allocates 32 megabytes of Java heap memory to the WebLogic Server, which improves performance and allows the WebLogic Server to handle more simultaneous connections. You may increase this value if necessary. See the WebLogic Server Performance Tuning Guide, for more details.
Instructions for starting the WebLogic Server using JView are available in Setting up and Starting the WebLogic Server.
Problems running WebLogic under Symantec?
I'm having some problems running the WebLogic Server under some versions of
Symantec's Java. Why is this?
We have had some reports of difficulties with Symantec's Java, including GPFs
when trying to run the WebLogic Server. Please use one of the JDKs we have certified,
listed on our Platform support page.
The WebLogic Console is reporting incorrect hostname and IP address
On the Server tab in the WebLogic Console, when I connect to myserver,
"loopback" and "127.0.0.1" are displayed. How can I get the correct information
displayed?
There is a bug in some VMs that does not correctly read the host name when
"localhost" is is the first entry in the hosts table. As a workaround, ask your system
administrator to move "localhost" from the top position of the hosts table
(/etc/hosts on UNIX) and then restart WebLogic Server.
What do you mean by a "log file"?
You asked me to send you a "logfile." What exactly do you mean?
We mean a stacktrace, or - if you are using the WebLogic Server - the
weblogic.log file in your WebLogic Server directory (the default is the myserver
directory).
You can generate a stacktrace in your code by inserting the following line of code after you catch an Exception "e".
e.printStackTrace();
There are several examples of using the printStackTrace() method in the code examples in the examples included with the distributions. All of the source code for the examples is also available on our website.
What are the java.io exceptions in the log file?
I see messages like these in the log file:
(Windows NT)
java.io.IOException Connection Reset by Peer
java.io.EOFException Connection Reset by Peer
(Solaris)
java.io.Exception: Broken pipe
These messages occur when you are using Servlets, a client initiates an HTTP
request, and then performs a series of actions on the browser:
The messages indicate that WebLogic Server has detected and recovered from an interrupted HTTP request.
|
|
|
Copyright © 2000 BEA Systems, Inc. All rights reserved.
|